package latin.service;

import latin.common.ServiceResponse;
import latin.pojo.User;

public interface IUserService {

    /**
     * 用户注册
     * @param user
     * @return
     */
    ServiceResponse<String> register(User user);

    /**
     * 用户登录
     * @param username
     * @param password
     * @return
     */
    ServiceResponse<User> login(String username,String password);

    /*
     * 查询用户设置的问题
     * @param username
     * @return
     */
    ServiceResponse selectQuestion(String username);


    ServiceResponse<String> getAnswer(String  username,String question,String answer);

    ServiceResponse<String> forgetResetPassword(String username,String password,String forgetToken);
    ServiceResponse<String> resetPassword(String passwordOld,String passwordNew,User user);
}
